package com.probox.common.core.enums;

/**
 * @author liuhj
 */

public enum CustomerGroupTypeEnum {

    shopHaveBuy("shopHaveBuy","店铺有购买"),
    shopNotBuy("shopNotBuy","店铺无购买"),
    shopHaveAddBuy("shopHaveAddBuy","店铺有加购"),
    shopNotAddBuy("shopNotAddBuy","店铺无加购"),
    validBugNumber("validBugNumber","有效购买次数"),
    validBuyMoney("validBuyMoney","有效购买金额"),
    shopHavePlaceOrder("shopHavePlaceOrder","店铺有下单"),
    shopNotPlaceOrder("shopNotPlaceOrder","店铺无下单"),
    notRefundOrderNumber("notRefundOrderNumber","无退款订单数"),
    memberLevel("memberLevel","会员等级"),
    sex("sex","性别"),
    integral("integral","积分");

    private CustomerGroupTypeEnum(String k, String v) {
        this.setKey(k);
        this.setValue(v);
    }

    public static String getNameByKey(String key) {
        String rst = "";
        for(CustomerGroupTypeEnum oe: CustomerGroupTypeEnum.values()) {
            if (oe.getKey().equals(key)) {
                rst = oe.getValue();
            }
        }
        return rst;
    }

    private String key;
    private String value;

    public String getKey() {
        return key;
    }
    public void setKey(String key) {
        this.key = key;
    }
    public String getValue() {
        return value;
    }
    public void setValue(String value) {
        this.value = value;
    }
}
